<!DOCTYPE html>
<html lang="zh-CN">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>172渲染赠品案例</title>
</head>

<body>
  <h1>172渲染赠品案例</h1>
  <div>
    <p class="gift"></p>
  </div>
  <script>
    const gift = '50g茶叶,清洗球'
    document.querySelector('.gift').innerHTML = gift.split(',').map(item => `<span class="tag">【赠品】${item}</span><br>`).join('')
  </script>
</body>

</html>